import service from '@/utils/request'

export const useSalesLogApi = (id: Number) => {
	return service.get('/sys/saleslog/' + id)
}

export const useSalesLogSubmitApi = (dataForm: any) => {
	if (dataForm.id) {
		return service.put('/sys/saleslog', dataForm)
	} else {
		return service.post('/sys/saleslog/save', dataForm)
	}
}
export const useSalesLogFileApi = (dataForm: any) => {
	return service.post('/sys/saleslog/savefile', dataForm)
}
export const useSalesLogListApi = (dataForm: any) => {
	return service.post('/sys/saleslog/list', dataForm)
}
